Skip to main content

All Questions

1vote
1answer
44views

Using a shortcode to get User Emails by role as specified in the shortcode, need help to allow for multiple roles

I have the following working code: function get_emails_by_multiple_roles ( $atts ) { $user_args = shortcode_atts ( array ( 'role' => 'role' , ), $atts ); $users = get_users( $...
Troy Rash's user avatar
0votes
0answers
37views

Shortcode to return data instead of outputting HTML?

I’ve got a shortcode plugin which allows me to output a block of HTML in one of a few different formats based on parameters. [mm-postlinking] [mm-postlinking id="281493" template="...
commadelimited's user avatar
1vote
0answers
33views

Custom Plugin not Displaying in the Website Production environment (Divi)

I built a custom plugin for a website Using Divi and I am facing a problem right now getting it to display in the production environment of the website. Here are the details: Since you can't really ...
BrigantiumXIX's user avatar
1vote
1answer
120views

How to get next day date of a specific day

I have created a shortcode in WordPress to show next day date of a specific day but it does not show the correct date when I am passing the parameter through the shortcode. Can anyone tell me what I ...
v morgesh's user avatar
0votes
0answers
23views

Plugin Inserts content before Page Content [duplicate]

I have a plugin that pulls comic book data from the Marvel API. I have assigned it a short code. When I place the shortcode on the page it does the following: Before: After inserting the shortcode it ...
user1689274's user avatar
1vote
1answer
62views

Resending woo-commerce order emails from frontend

I am trying to create a simple shortcode [resend_woo_emails]. This shortcode will create a form with a dropdown with all email classes, an input field for cc emails, and another input field for ...
Joy's user avatar
  • 31
0votes
0answers
73views

Display file contents within Plugin

Does anyone know what I am doing wrong - I try to display forms from different files within my plugin. all is triggerd by my_shortcode where the via $atts the user choses which form to display. This ...
gladys's user avatar
0votes
1answer
47views

Developing an IP lookup function using an API

I'd like to implement the ability to incorporate an API into my Wordpress blog that allows people to perform an IP lookup within my blog. So far all of my attempts have failed when incorporating the ...
skarz's user avatar
0votes
0answers
96views

Shortcode cannot parse attributes within double quotes. " is becoming ” breaking my shortcode

I made a plugin that creates a shortcode to calculate the time since a particular date in the past. It has two attributes, a date string and units: function timesince_shortcode($atts) { $atts = ...
Sidewinder's user avatar
1vote
1answer
1kviews

Custom plugin with shortcode not working

I have a long-term client with a ton of custom shortcodes and functions for miscellaneous purposes we've accrued over the years and I decided to re-home them into a custom plugin so I didn't have to ...
Vanderbeam's user avatar
0votes
0answers
53views

WP Custom tables query

I returned to PHP / MySQL development after a long break, and I am working on a project that requires some customization. First, I added a credentials file; then I am referencing that file in my test ...
Sam's user avatar
0votes
0answers
52views

Shortcode rendered in preview, but empty in post

My issue is related to this one: Shortcode not being executed But I can see my shortcode in action, when I preview the post, but I can't if I save it and view it regularly. This is my callback for the ...
UNeverNo's user avatar
0votes
2answers
556views

Wordpress simple 'Hello World' plugin - problems

I am an old-school embedded C programmer but a WP noob, so please bear with me. Here is what I have done so far:- Added a Shortcode in a Theme My function prints out 'Hello World' and is registered ...
quixote's user avatar
0votes
0answers
20views

Font size of HTML content

I am developing a plugin. In this plugin I am outputting some HTML using short-code. User can choose font size of HTML content from Admin Panel. This plugin is saving font size as meta value in ...
Foysal's user avatar
-1votes
2answers
2kviews

How to Pass ID through Short Code

How to Pass ID and fetch post meta data through Short Code like [my-shortcode id="12"] ? My code is like below. add_shortcode( 'my-shortcode', 'shortcode_function' ); function ...
Foysal's user avatar

153050per page
close